import com.xuggle.mediatool.IMediaReader;
import com.xuggle.mediatool.IMediaWriter;
import com.xuggle.mediatool.ToolFactory;

public class FileFileTranscoder {

	private String in;
	private String out;

	
	public FileFileTranscoder(String inFile, String outFile) {
		
		in = inFile;
		out = outFile;
	}
	

	public void exec() {
		
		IMediaReader reader = ToolFactory.makeReader(in);
		IMediaWriter writer = ToolFactory.makeWriter(out, reader);
		reader.addListener(writer);
		writer.addListener(ToolFactory.makeDebugListener());
		while (reader.readPacket() == null)	;
	}

}
